﻿using System.Configuration;

namespace AppFx.BizTalk.Container.Config
{
    public class ContainerElement : ConfigurationElement
    {
        /// <summary>
        /// The key/name for the sender configuration
        /// </summary>
        [ConfigurationProperty("name", IsRequired = true, IsKey = true)]
        public string ContainerName
        {
            get { return (string)this[@"name"]; }
        }
        /// <summary>
        /// The type of loader to use
        /// </summary>
        /// <remarks>
        /// BRE = BizTalk Business Rule
        /// CONFIG = Config Section
        /// Custom Type = Custom .net type which call will be deferred to
        /// </remarks>
        [ConfigurationProperty("loaderType", IsRequired = true)]
        public string LoaderType
        {
            get { return (string)this[@"loaderType"]; }
        }
        /// <summary>
        /// The key for the loader
        /// </summary>
        [ConfigurationProperty("loaderKey", IsRequired = false)]
        public string LoaderKey
        {
            get { return (string)this[@"loaderKey"]; }
        }       
    }
}

